<!DOCTYPE html>
<html lang="en" style="width:99%;height:99%;border:5px solid #99bbe8;margin:0 auto;border-radius:10px;">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
	<meta http-equiv="X-UA-Compatible" content="IE=7" />
    <script src="js/ext-base.js" type="text/javascript"></script>
    <script src="js/ext-all.js" type="text/javascript"></script>
    <link href="css/MainStyle.css" rel="stylesheet" type="text/css" />
    <script src="js/cAlert.js" type="text/javascript"></script>
    <script src="js/WdatePicker.js" type="text/javascript"></script>
    
    
    <link href="css/jquery-ui-1.8.18.custom.css" rel="stylesheet" type="text/css" />
    
    <script src="js/jquery.js" type="text/javascript" charset="utf-8"></script>
    <script src="js/jquery-ui-1.8.18.custom.min.js" type="text/javascript"></script>
    <script src="js/autoComplete.js" type="text/javascript"></script>
    
    <script src="js/jquery.cookies.2.2.0.min.js" type="text/javascript"></script>

    <link href="css/Loading.css" rel="stylesheet" type="text/css" />
    <link href="css/Css.css" rel="stylesheet" type="text/css" />
    <link href="css/ext-all.css" rel="stylesheet" type="text/css" />
    <script src="js/ALLEvents.js" type="text/javascript"></script>
    <script src="js/Main.js" type="text/javascript"></script>
    <script src="js/cngrain_time.js" type="text/javascript"></script>

 
    <style type="text/css">
        *
        {
            margin: 0px;
            padding: 0px;
        } 
        .page
        {
            text-align: center;
            margin-top: 15px;
        }
        .page .pageBtn
        {
            margin: 0px 10px 0px 10px;
            font-size: 20px;
            line-height: 22px;
            color: blue;
            display: -moz-inline-box;
            display: inline-block;
            min-width: 30px;
        }
        .page .disablePageBtn
        {
            border: none;
            color: Gray;
        }
        .page .curPageBtn
        {
            border: none;
            color: Gray;
            font-weight: bold;
        }
        .page .enablePageBtn
        {
            border: 1px solid #e7e4f0;
        }
        .page .enablePageBtn:hover
        {
            border: 1px solid #ebebeb;
            background-color: #ebebeb;
        }
        .page .enablePageBtn
        {
            cursor: hand;
            cursor: pointer;
        }
        .page .prePage
        {
        }
        .page .nextPage
        {
        }
        
        .mainx
        {
            width: auto;
        }
        .Childx
        {
            width: 150px;
            float: left;
        }
        .ui-button
        {
            margin-left: 0px;
        }
        .ui-button-icon-only .ui-button-text
        {
            padding: 0.15em;
        }
        .ui-autocomplete-input
        {
            margin: 0;
            padding: 0.18em 0 0.18em 0.18em;
            font-size: 12px;
        }
        .Company
        {
            width: 260px;
        }
        .City
        {
            width: 80px;
        }
        .Granary
        {
            width: 260px;
        }
        .GranaryDC
        {
            width: 260px;
        }
        li
        {
            height: 18px;
            font-size: 8px;
        }
        .iConButton, .storeButton
        {
            cursor: hand;
            cursor: pointer;
        }
        .CheckColor
        {
            background-color: #D9E7F8;
        }
        .GrainColor
        {
            background-color: #F1EDED;
        }
        .Start
        {
            color: red;
        }
        .gid
        {
            margin-top: 5px;
        }
        .gidTitle
        {
            background-color: white;
            border:1px solid #B5CEED;
        }
        
        .imgweather
        {
            border: 0px;
            width: 24px;
            height: 24px;
        }
        .granaryText
        {
            
            font-size: 16px;
            font-weight: bold;
            margin-left: 10px;
        }
        .weatherInfoTitle
        {
            font-size: 14px;
            color: red;
            font-weight: bold;
            margin-left: 20px;
        }
        .weatherInfo
        {
        }
        .checkinfo1, .checkinfo2
        {
        }
        .checkinfo2
        {
            color: Red;
            clear: both;
        }
        .gidShow
        {
            float: left;
            width: 35px;
            height: 35px;
        }
        .gidblock, #divComments
        {
            display: none;
        }
        #ulNav
        {
            margin: 0px auto;
            text-align: center;
        }
        #ulNav .liItem
        {
            width: 250px;
            height: 167px;
            list-style-type: none;
            float: left;
            margin: 5px;
            display: none;
        }
        .ulWarning li
        {
            list-style-type: none;
            float: left;
            
            width: 160px;
            margin: 5px;
        }
        #ulNav .li_gname
        {
            font-weight: bold;
            font-size: 15px;
        }
        #ulNav .li_div_Item
        {
            border: 1px solid #8daad1;
        }
        #ulNav .li_div_img
        {
            height: 123px;
        }
        #ulNav .li_div_name
        {
            text-align: left;
            margin-top: 10px;
        }
        #ulNav .emptywarning
        {
            color: Red;
            font-weight: bold;
        }
        #ulNav .dashedline
        {
            border-bottom: 1px dashed #8daad1;
            height: 1px;
            overflow: hidden;
            clear: both;
        }
        #ulNav .wf1
        {
            font-weight: bold;
        }
        #ulNav .wf1, #ulNav .wf2, #ulNav .wf3, #ulNav .wf4, #ulNav .wf5
        {
            font-size: 12px;
        }
        #ulNav .houseinfo
        {
            font-size: 13px;
            padding-left: 20px;
        }
        #ulNav .li_table
        {
            border-width: 0px;
            display: block;
            width: 100%;
        }
        #ulNav .li_imgtd_
        {
            width: 76px;
            border-width: 0px;
        }
        #ulNav .li_nametd
        {
            border-width: 0px;
            vertical-align: top !important;
        }
        #ulNav, #ulNav table, #ulNav td, #ulNav .li_a_gname
        {
            color: #8daad1 !important;
        }
        #ulNav .weatherImg
        {
            border: 0px;
            width: 22px;
            height: 22px;
        }
        #ulNav .li_div_weather, #ulNav .wf1, #ulNav .wf2, #ulNav .wf3, #ulNav .wf4, #ulNav .wf5
        {
            vertical-align: middle;
            text-align: left;
        }
        #ulNav .li_a_gname:hover
        {
            color: Red !important;
        }
        #ulNav .li_a_gname
        {
            cursor: hand;
            cursor: pointer;
        }
       
        .huizongname
        {
            cursor: hand;
            cursor: pointer;
        }
        #btnShowAll
        {
            cursor: hand;
            cursor: pointer;
        }
    </style>
    <style type="text/css">
        #loading
        {
            position: absolute;
            left: 45%;
            top: 40%;
            padding: 2px;
            height: auto;
        }
        .mask
        {
            background-color: #72a3e2;
            left: 0;
            top: 0;
            opacity: 0.2;
            overflow: hidden;
            position: absolute;
            width: 100%;
            height: 100%;
            z-index: 900;
            filter: progid:DXImageTransform.Microsoft.Alpha(style=3,opacity=12,finishOpacity=15);
        }
        .imgWeidu{ width:16px; height:16px;}
    </style>







    <script type="text/javascript">

        function ShowInfo(str) {
            var url = "ViewStoreInfo.aspx?ID=" + str + "&GranaryID=" + $("#hdGranary").val();
            show("仓房详细信息", url, 480, 810, 1);
        }
        function ShowInfo2(str, str1, str2) {

            //var url = "TempDetail.aspx?gid=" + str + "&housid=" + str1 + "&datetime=" + str2 + "&companyid=" + document.getElementById("ddlOrg").value;
            var url = "TempDetail.aspx?gid=" + str + "&housid=" + str1 + "&datetime=" + str2 + "&companyid=" + $("#hdCompany").val();
            //show("粮仓测控数据详情", url, 450, 650, 1);
            show("粮仓测控数据详情", url, 600, 900, 1);
        }
        function openVideoView(granaryID, storeHouseID) {

            var url = "../VideoServer/VideoServer.aspx?GranaryID=" + granaryID + "&storeHouseID=" + storeHouseID;
            show("仓房视频监控信息", url, 610, 1020, 1);
        }
        function openReports(storehouseID, serialno2, analytime) {
            //var url = "StoreHouseCurrentReportManage.aspx?storehouseid=" + storehouseID + (serialno2 == "" ? "" : ("&serialno2=" + serialno2)) + "&analytime=" + analytime;
            //show("仓房储量状态简报", url, 470, 900, 1);

            if (confirm("是否要到仓房储粮简报管理页面？"))
            { openPanelWithMenu2() };
        }
        function openPanelWithMenu2() {
            var node_id = "003021";
            var node_text = "仓房储粮简报管理";
            var node_url = "Pages/StoreWarning/StoreHouseBriefReportInfoForWaiWang.aspx";
            var v = node_url.indexOf("top=1", 0);
            if (v >= 0) {
                //                if (top != self)
                //                    top.location = node_url;
                //                else
                //                    self.location = node_url;
                var newpage = window.open(node_url);
                newpage.blur();
                return;
            }
            var n = window.top.center.getComponent(node_id);

            if (n) {//判断是否已经打开该面板
                window.top.center.remove(n);
            }
            n = window.top.center.add({
                xtype: "panel",
                id: node_id,
                iconCls: 'totalicon',
                title: node_text,
                closable: true,  //通过html载入目标页
                html: '<iframe scrolling="auto" frameborder="0" width="100%" height="100%" src="' + node_url + '"></iframe>'
            });
            window.top.center.setActiveTab(n);
        }

        function openEmptyAutoLookView(companyId, granaryID, time) {

            var url = "js/EmptyStoreWarningAutoLook.aspx?CompanyID=" + companyId + "&GranaryID=" + granaryID + "&Time=" + time + "&GranaryName=" + $("#hdGranaryName").val();
            show("空仓巡检" + " (" + $("#hdCompanyName").val() + ")", url, 585, 1024, 1);
        }
        //*******

        //鼠标移入显示仓库预警图

        //*******

        function yiru(img) {
            var ei = document.getElementById("big_image");
            ei.style.display = "block";
            var htmlstrt = "";
            var list = new Array();
            list = img.split(',');
            for (var i = list.length - 1; i >= 1; i--) {
                if (list[i] == "1")//空层
                { htmlstrt += "<div style='height:15px;width:auto;background-image:url(imgs/ceng.gif);background-color:Red;text-align:center;'>空</div>"; }
                else
                { htmlstrt += "<div style='height:15px;width:auto;background-image:url(imgs/ceng.gif);text-align:center;'>满</div>"; }
            }
            ei.innerHTML = "<div style='width:92px;'><div style='width:auto;'><img src='imgs/toppp.bmp' border='0' /></div>" + htmlstrt + "</div>";
            ei.style.top = document.body.scrollTop + window.event.clientY + 10 + "px";
            ei.style.left = document.body.scrollLeft + window.event.clientX + 10 + "px";
        }


        //*******

        //鼠标移出隐藏仓库预警图

        //*******

        function yichu() {
            var ei = document.getElementById("big_image");
            ei.innerHTML = "rrr.jpg";
            ei.style.display = "none";
        }
        function openPanelWithMenu(node_id, node_text, node_url) {
            var v = node_url.indexOf("top=1", 0);
            if (v >= 0) {
                var newpage = window.open(node_url);
                newpage.blur();
                return;
            }
            var n = window.top.center.getComponent(node_id);

            if (n) { //判断是否已经打开该面板
                window.top.center.remove(n);
            }
            n = window.top.center.add({
                xtype: "panel",
                id: node_id,
                iconCls: 'totalicon',
                title: node_text,
                closable: true,  //通过html载入目标页
                html: '<iframe id="f_' + node_id + '" scrolling="auto" frameborder="0" width="100%" height="100%" src="' + node_url + '"></iframe>'
            });
            window.top.center.setActiveTab(n);
        }
        //获取时间
        function CurentTime() {
            var now = new Date();

            var year = now.getFullYear();       //年
            var month = now.getMonth() + 1;     //月
            var day = now.getDate();            //日

            var hh = now.getHours();            //时
            var mm = now.getMinutes();          //分

            var clock = year + "-";

            if (month < 10)
                clock += "0";

            clock += month + "-";

            if (day < 10)
                clock += "0";

            clock += day + " ";

            //            if (hh < 10)
            //                clock += "0";

            //            if (mm < 10)
            //                clock += "0";

            return (clock);
        }

        $(document).ready(function () {
            $(".storeTable").each(function () {//超出大小时候隐藏，防止单元格中的内容宽度大于单元格宽度时候换行
                var v = $(this).find("td").eq(0);//仓房名称单元格
                v.html("<div style='width:145px; overflow:hidden; white-space:nowrap; word-break: break-all;' title='" + v.text() + "'>" + v.html() + "</div>");
                v = $(this).find("td").eq(4);//储粮单元格
                if (v.html()!=null&&v.html().indexOf("]")>=0&&v.html().indexOf("[")>=0&&v.html().indexOf("]")-v.html().indexOf("[")>3)//.indexOf("食用油") >= 0)
                    v.html("<div style='width:90px; overflow:hidden; white-space:nowrap; word-break: break-all;' title='" + v.text() + "'>" + v.html() + "</div>");
                v = $(this).find("td").eq(6);//储粮单元格
                if (v.html()!=null&&v.html().indexOf("]")>=0&&v.html().indexOf("[")>=0&&v.html().indexOf("]")-v.html().indexOf("[")>3)//.indexOf("食用油") >= 0)
                    v.html("<div style='width:90px; overflow:hidden; white-space:nowrap; word-break: break-all;' title='" + v.text() + "'>" + v.html() + "</div>");
            });
            changeview();
            //加载AutoComplete全部数据
            Loding("DC0000000356957", "光山县同富粮食贸易有限责任公司库点", "YHLX0105", "");

            //$("#hdWindowWidth").val($(window).width());  //获取当前初始化页面可视窗口的宽度

            //查询提示
            $(".Query").click(function () {
                $("#hdWindowWidth").val($(window).width());  //获取当前可视窗口的宽度
                $("#hdWindowHeight").val($(window).height());
                if ($("#hdCompany").val() == "") {
                    alert('请选择分公司！');
                    $(".Company_AutoComplete").next("input").focus();
                    return false;
                }
                if ($("#hdGranaryDC").val() == "") {
                    alert('请选择粮库！');
                    $(".Granary_AutoComplete_DC").next("input").focus();
                    return false;
                }
                if (document.getElementById("txtTime").value == "") {
                    alert('请选择时间！');
                    return false;
                }
                if ($("#hdGranaryDC").val() == "-1")
                    $("#divMask").show();
            })
            //空仓巡检
            $("#btn_QueryInspection").click(function () {

                $("#hdWindowWidth").val($(window).width());  //获取当前可视窗口的宽度

                if ($("#hdCompany").val() == "") {
                    alert('请选择分公司！');
                    $(".Company_AutoComplete").next("input").focus();
                    return false;
                }
                else {
                    openEmptyAutoLookView($("#hdCompany").val(), $("#hdGranary").val(), $("#txtTime").val());
                    return false;
                }
            })

            //功能跳转
            $(".RedirectOtherPage").click(function () {
                if ($("#hdCompany").val() == "") {
                    alert('请选择分公司！');
                    $(".Company_AutoComplete").next("input").focus();
                    return false;
                }
                if (($("#hdGranaryDC").val() == "-1") && $(this).attr("data-canall") == "0") {
                    alert('请选择粮库！');
                    $(".Granary_AutoComplete_DC").next("input").focus();
                    return false;
                }
                if (document.getElementById("txtTime").value == "") {
                    alert('请选择时间！');
                    return false;
                }

                var checkUrl = $(this).attr("lang");   //获取要跳转到的页面
                var checkText = $(this).val();         //获取Select选择的Text 
                var checkValue = $(this).attr("validationgroup");                                 //获取Select选择的Value 

                openPanelWithMenu(checkValue, checkText, checkUrl + "?gid=" + $("#hdGranary").val() + "&GranaryName=" + $("#hdGranaryName").val() + "&GidDc=" + $("#hdGranaryDC").val() + "&datetime=" + CurentTime() + "&windowWidth=" + $("#hdWindowWidth").val())
            });
            //显示/隐身仓房分类
            $("#storeSort").toggle(
                function () {
                    $(this).val("汇总↑").attr("title", "隐藏汇总");
                    $("#dvStoreSort").fadeIn("slow");
                },
                function () {
                    $(this).val("汇总↓").attr("title", "查看汇总");
                    $("#dvStoreSort").fadeOut("fast");
                });
            //查看仓房明细
            $(".storeTable").live({
                mouseenter: function () {
                    $(this).find("td").css("color", "red");
                    $(this).css({ "cursor": "hand", "text-decoration": "underline" })
                },
                mouseleave: function () {
                    $(this).find("td").css("color", "black");
                    $(this).css("text-decoration", "none")
                }
            });
            $(".storeTable").live("click", function () {
                var StoreID = $(this).attr("lang");
                ShowInfo(StoreID);
            });
            $(".storeButton").click(function () {
                var StoreID = $(this).attr("id");
                ShowInfo(StoreID);
            });
            //按分类查询仓房
            $(".iConButton").click(function () {
                var StoreStatus = $(this).find("img").attr("id");
                var data_warningtext = $(this).attr('data-warningtext');
                ShowWarningType(StoreStatus, data_warningtext);

                //                $("#hdStoreStatus").val(StoreStatus);

                //                $("#btn_Query").click();
            });
            $(".iConButton").hover(
                function () {
                    $(this).find("label").css("color", "red");
                    $(this).find("label").css("text-decoration", "underline")
                },
                 function () {
                     $(this).find("label").css("color", "black");
                     $(this).find("label").css("text-decoration", "none")
                 });
            $(".storeButton").hover(
                function () {
                    $(this).css("color", "red");
                    $(this).css("text-decoration", "underline")
                },
                function () {
                    $(this).css("color", "black");
                    $(this).css("text-decoration", "none")
                });
            //返回全部仓房信息
            $("#btnQueryAll").click(function () {
                $("#btn_Query").click();
            });
            $("[data-attclick]").click(function () {
                var nowGid = $(this).attr("data-gid");
                showGid(nowGid);
            });
            $("#btnreturn").click(function () {
                returnNav();
            });
            $("[data-huizong-gid]").click(function () {
                var gid = $(this).attr('data-gid');
                showGid(gid);
                ShowWarningType('', '');
            });
            $(".checktime").attr("title", "粮情平台检测分析时粮食储量");
            $(".grain").attr("title", "保管员最后更新粮食储量 ");
            $("#selectSortMethod").change(function () {
                changeview();
            });
            function changeview() {
                //return;
                var selected = $("#selectSortMethod").children('option:selected');
                //alert(selected.val());
                if (selected.val() == "0") {
                    //                    //$("#dvSortByHouseID").empty();
                    //                    $.each($("[data-index]"), function (index, ob) {
                    //                        $(this).remove().appendTo($("#dvSortByHouseID"));
                    //                    });
                    //                    $("#dvSortByChubei").empty();

                    //////////
                    $.each($(".SortByChubei"), function (gidindex, gidob) {
                        var gid = $(this).attr("data-gid");
                        var sortbyhouseid = $("#dvSortByHouseID" + gid);
                        $.each($("#dvSortByChubei" + gid + " [data-chubei]"), function (cangIndex, cangOb) {
                            $(this).remove().appendTo(sortbyhouseid);
                        });
                        $(this).empty();
                    });


                }
                else if (selected.val() == "1") {
                    //                    $("#dvSortByChubei").empty();
                    var chubeis = ['ZC', 'ZD', 'LC', 'TC', 'HC', 'SC'];
                    var chubeinames = ["中央储备", "托市粮", "临时储备", "特种储备", "混合储备", "商品储备"];

                    $.each($(".SortByHouseID"), function (gidindex, gidob) {
                        var gid = $(this).attr("data-gid");
                        var sortbychubei = $("#dvSortByChubei" + gid);
                        $.each($("#dvSortByChubei" + gid + " [data-chubei]"), function (cangindex, cangob) {

                        });

                        $.each(chubeis, function (cbi, cb) {
                            var items = $("#dvSortByHouseID" + gid).find(" [data-chubei='" + cb + "']");
                            if (items.length > 0) {
                                var obcbi = $("<div style='margin:3px 0px;'><div style=\" width:131px;background:url('imgs/title-bg.png') no-repeat;\"><table style='border:none;'><tr><td style=' text-align:center; width:80px; border:none;'><span >" + chubeinames[cbi] + "</span></td><td style='width:50px; text-align:center; border:none;' class='shouqi' ><img src='imgs/down.png' /></td></tr></table></div></div>");
                                var obcbiContainer = $("<div></div>");
                                obcbiContainer.appendTo(obcbi);
                                $.each(items, function (i, val) {
                                    $(this).remove().appendTo(obcbiContainer);
                                });
                                $("<div style='clear:both;'></div>").appendTo(obcbi);
                                obcbi.appendTo(sortbychubei);
                            }
                        });
                        $(this).empty();
                    });


                }
            }

            $(".shouqi").live('click', function () {
                $(this).parent().parent().parent().parent().next().slideUp();
                $($(this).children().eq(0)).attr('src', 'imgs/up.png');
                $(this).removeClass("guanbi");
                $(this).addClass("zhankai");
            });
            $(".zhankai").live('click', function () {
                $(this).parent().parent().parent().parent().next().slideDown();
                $($(this).children().eq(0)).attr('src', 'imgs/down.png');
                $(this).removeClass("zhankai");
                $(this).addClass("shouqi");
            });
        })
        //显示某个库的仓房预警
        function showGid(nowGid) {
            $("#dvNav").hide();
            var nowGid2 = $("#btnreturn").attr('data-nowgid');
            if (nowGid2 != undefined) {
                $("#warninggid" + nowGid2).hide();
                //alert(nowGid2);
            }
            $("#btnreturn").attr('data-nowgid', nowGid);
            var docWidth = $(window).width(); // document.documentElement.clientWidth;
            var docHeight = $(window).height(); // document.documentElement.clientHeight;
            //            alert(docWidth + "," + docHeight);
            //            alert($(window).width() + "," + $(window).height());
            var perLiWidth = 163; //  $(".ulWarning li")[0].width();
            var hNum = Math.floor((docWidth - 20) / perLiWidth); //水平方向放几个。20是滚动条
            if (hNum <= 0)
                hNum = 1;
            var permargin = Math.abs(Math.floor((docWidth - hNum * perLiWidth - 20) / (hNum * 2)));
            //alert(perLiWidth + "," + hNum + "," + docWidth + "," + permargin);
            $.each($(".ulWarning li"), function () {
                $(this).css('margin-left', permargin + 'px');
                $(this).css('margin-right', permargin + 'px');
            });
            $("#divComments").show();
            $("#warninggid" + nowGid).show();
            $(".ulWarning").attr('min-width', docWidth);
            $(".ulWarning").attr('overflow', 'scroll');
        }
        //返回到导航
        function returnNav() {

            $("#dvNav").show();
            $("#divComments").hide();
            var nowGid = $("#btnreturn").attr('data-nowgid');
            if (nowGid != undefined)
                $("#warninggid" + nowGid).hide();
        }
        //显示某个预警类型
        function ShowWarningType(StoreStatus, data_warningtext) {
            if (StoreStatus != "") {
                var num = 0;
                $.each($("[data-li-statusid]"),
                function () {
                    var s = $(this).attr('data-li-statusid');
                    if (s != StoreStatus) {
                        $(this).parent().hide();
                    }
                    else {
                        $(this).parent().show(); num++;
                    }
                });
                $("#btnShowAll").show();
                $('#nowWarningText').html('当前类型:【<span style="font-weight:bold;">' + data_warningtext + '</span>】，共' + num + '个');
                $("#divShowAllType").show();
            }
            else {
                $.each($("[data-li-statusid]"), function () { $(this).parent().show(); });
                $("#btnShowAll").hide();
                $('#nowWarningText').html('');
                $("#divShowAllType").hide();
            }

        }
    </script>
    <script type="text/javascript" language="javascript">

        $(document).ready(function () {
        var gc=0;
        //gc=999;//如果不是查询全部，而是查询某一个库的时候也显示导航视图，则取消注释即可
        //if (gc > 1) 
        {
            var docWidth=$(window).width();
            var docHeight=$(window).height();
            if($("#hdWindowWidth").val()!='')
                docWidth =$("#hdWindowWidth").val();// $(window).width(); // document.documentElement.clientWidth;
            if($("#hdWindowHeight").val()!='')
                docHeight =$("#hdWindowHeight").val();// $(window).height(); // document.documentElement.clientHeight;
            //            alert(docWidth + "," + docHeight);
            //            alert($(window).width() + "," + $(window).height());
            var mTop = 165;
            var perLiWidth = 250;
            var perLiHeight = 175;
            var hNum = Math.floor((docWidth - 20) / perLiWidth);
            if (hNum <= 0)
                hNum = 1;
            var vNum = Math.floor((docHeight - mTop) / perLiHeight);
            if (vNum <= 0)
                vNum = 1;
            if ($('#ulNav').length > 0) {
                var totalItemCount = $("#ulNav .liItem").length;
                if (totalItemCount > 0) {
//                    $("#ulNav").css('min-width', docWidth);
//                    $("#ulNav").css('overflow', 'scroll');
                    var ulpermargin = Math.abs(Math.floor((docWidth - hNum * perLiWidth - 20) / (hNum * 2)));
                    $.each($("#ulNav .liItem"), function () {
                        $(this).css('margin-left', ulpermargin + 'px');
                        $(this).css('margin-right', ulpermargin + 'px');
                    });
                    goPage(1, hNum * vNum);
                }
            }
            }
            if(gc==1) {        
            showGid('');
            //$("#btnreturn").hide();//如果不是查询全部，而是查询某一个库的时候也显示导航视图，则取消注释即可
        }
        });
        var curpageindex;
        function prePage(perPageItemCount) {
            goPage(curpageindex - 1, perPageItemCount);
        }
        function nextPage(perPageItemCount) {
            goPage(curpageindex + 1, perPageItemCount);
        }
        function goPage(toPage, perPageItemCount) {
            var totalItemCount = $("#ulNav .liItem").length;
            var totalPageCount = Math.ceil(totalItemCount / perPageItemCount);
            createPages(toPage, perPageItemCount, totalPageCount);
            createHTML(toPage, perPageItemCount, totalItemCount, totalPageCount);
            curpageindex = toPage;
        }
        function createPages(toPage, perPageItemCount, totalPageCount) {
            var pageHtml = "";
            pageHtml += ("<span class='pageBtn") + (toPage <= 1 ? " disablePageBtn'" : " enablePageBtn' onclick='prePage(" + perPageItemCount.toString() + ")'") + ("><span>上一页</span></span>");
            for (var i = 1; i < totalPageCount + 1; i++) {
                if (i != toPage)
                    pageHtml += ("<span class='pageBtn enablePageBtn' data-type='pageBtn' data-page='" + i.toString() + "' onclick='goPage(" + i.toString() + "," + perPageItemCount.toString() + "," + totalPageCount.toString() + ")'><span>" + i.toString() + "</span></span>");
                else
                    pageHtml += ("<span class='pageBtn curPageBtn' data-type='pageBtn' data-page='" + i.toString() + "' ><span>" + i.toString() + "</span></span>");
            }
            pageHtml += ("<span class='pageBtn") + (toPage >= totalPageCount ? " disablePageBtn'" : " enablePageBtn' onclick='nextPage(" + perPageItemCount.toString() + ")'") + ("><span>下一页</span></span>");
            $("#pageContainer").html(pageHtml);
        }
        function createHTML(toPage, perPageItemCount, totalItemCount, totalPageCount) {
            var from = (toPage - 1) * perPageItemCount + 1;
            var end = toPage * perPageItemCount;
            $.each($("#ulNav .liItem"), function (index) {
                if (index + 1 >= from && index + 1 <= end) {
                    $(this).show();
                }
                else
                    $(this).hide();
            });
        }
    </script>
</head>

<body class="ext-webkit ext-chrome " >





	 <form name="form1" method="post" action="EmptyStoreWarningSubNav.aspx" id="form1">
<div>
<input type="hidden" name="__VIEWSTATE" id="__VIEWSTATE" value="/wEPDwULLTE3Njc2MjA1MDkPZBYCAgMPZBYIAgoPFgIeB1Zpc2libGVnZAIMDw8WAh4EVGV4dAXYDjxkaXYgaWQ9ImR2U3RvcmVTb3J0IiBzdHlsZT0iZGlzcGxheTpub25lIj48dGFibGUgd2lkdGg9IjEwMCUiIGNsYXNzPSJub2JvZGVyIj48dHI+PHRkIGNvbHNwYW49IjQiIGNsYXNzPSJ0ZHRocmVhZCI+5LuT5oi/5YiG57G7PC90ZD48L3RyPjx0cj48dGggc3R5bGU9IndpZHRoOjIwMHB4O3RleHQtYWxpZ246bGVmdDsiPueyruW6kzwvdGg+PHRoIHN0eWxlPSJ3aWR0aDoyMCU7dGV4dC1hbGlnbjpjZW50ZXIiPuS7k+aIv+exu+WeizwvdGg+PHRoIHN0eWxlPSJ3aWR0aDoxMCU7dGV4dC1hbGlnbjpjZW50ZXIiPuS7k+aIv+aAu+aVsDwvdGg+PHRoIHN0eWxlPSJ0ZXh0LWFsaWduOmNlbnRlciI+5LuT5oi/5ZCN56ew5YiX6KGoPC90aD48L3RyPjx0cj48dGQgcm93c3Bhbj0iMiIgIHN0eWxlPSJ0ZXh0LWFsaWduOmxmZXQiPjxhIGNsYXNzPSdodWl6b25nbmFtZScgZGF0YS1naWQ9J0RDMDAwMDAwMDM1Njk1NycgZGF0YS1odWl6b25nL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AI32j33g9bJUxuxOZpYoBhg/6FnpjKlUBrqRaj3LD" />
</div>

<div>

	<input type="hidden" name="__EVENTVALIDATION" id="__EVENTVALIDATION" value="/wEWFQLOs/ziCgKjzu7EAQK+5ZrtBQK/z9zDCQK8hMyGBgLN84PrDgKDueP9CALpgIOeCwL8xc2/AwLe07KVAwL02tD3DwLzhaL/DgKk2/vQAwLF/c//CwLbxK63CAKe3Y3gBQLm2aexAQLzjumbDwKYyPuGCAKa8LPSAgLluvS0AdgYcnXBCDTx5E6ulOoS6eAQR/XmBsA9DT7yYqP4Tx6A">
</div>

<div>

	<input type="hidden" name="__EVENTVALIDATION" id="__EVENTVALIDATION" value="/wEWFAKrxv+7DAKjzu7EAQK+5ZrtBQK/z9zDCQK8hMyGBgLN84PrDgKDueP9CALpgIOeCwL8xc2/AwL02tD3DwLzhaL/DgKk2/vQAwLF/c//CwLbxK63CAKe3Y3gBQLm2aexAQLzjumbDwKYyPuGCAKa8LPSAgLluvS0AWGL7f+sbKz5rqDEf9sLNcqfcqU/Mp7uQSRVKQEb6uPA" />
</div>

        <div>
            <div id="big_image" style="position: absolute; display: none; z-index: 2; border: 0px solid #f4f4f4;">
            </div>
            <table width="100%" class="noboder">
                <tbody><tr>
                    <td colspan="4" class="tdthread">
                        空仓预警
                    </td>
                </tr>
                <tr class="noboder">
                    <td colspan="4">
                        <table width="100%"> 
                            <tbody><tr class="noboder">
                                <td class="tbtitle">
                                    分公司：
                                </td>
                                <td class="tbright">
                                    &nbsp;
                                    <select name="" id=""><option value="中国储备粮管理总公司河南分公司">中国储备粮管理总公司河南分公司</option></select>
                                    <!-- <select name="ddl_Company_AutoComplete" id="ddl_Company_AutoComplete" mark="Company" class="Company_AutoComplete" style="display: none;">
<option value="">Select one...</option><option value="SA0000000000035" title="zhongguochubeiliangguanlizonggongsihenanfengongsi">中国储备粮管理总公司河南分公司</option></select> --><!-- <input class="Company ui-autocomplete-input ui-widget ui-widget-content ui-corner-left" autocomplete="off" role="textbox" aria-autocomplete="list" aria-haspopup="true"><button type="button" style="font-size: 12px; height: 24px;" tabindex="-1" title="显示全部信息！" class="ui-button ui-widget ui-state-default ui-button-icon-only ui-corner-right .ui-button-icon-only" role="button" aria-disabled="false"><span class="ui-button-icon-primary ui-icon ui-icon-triangle-1-s"></span><span class="ui-button-text">&nbsp;</span></button> -->
                                </td>
                                <td class="tbtitle">
                                    直属库：
                                </td>
                                <td class="tbright">
                                    
                                    &nbsp;
                                    <select name="" id=""><option value="中央储备粮潢川直属库">中央储备粮潢川直属库</option></select>
                                    <!-- <select name="ddl_Granary_AutoComplete" id="ddl_Granary_AutoComplete" class="Granary_AutoComplete" mark="Granary" style="display: none">
<option value="">Select one...</option><option value="SA0000000000401" title="zhongyangchubeiliangzuochuanzhishuku">中央储备粮潢川直属库</option></select><input class="Granary ui-autocomplete-input ui-widget ui-widget-content ui-corner-left" autocomplete="off" role="textbox" aria-autocomplete="list" aria-haspopup="true"><button type="button" style="font-size: 12px; height: 24px;" tabindex="-1" title="显示全部信息！" class="ui-button ui-widget ui-state-default ui-button-icon-only ui-corner-right .ui-button-icon-only" role="button" aria-disabled="false"><span class="ui-button-icon-primary ui-icon ui-icon-triangle-1-s"></span><span class="ui-button-text">&nbsp;</span></button> -->
                                </td>
                            </tr>
                            <tr class="noboder">
                                <td class="tbtitle">
                                    粮库：
                                </td>
                                <td class="tbright">
                                    &nbsp;
                                    <select name="" id=""><option value="光山县同富粮食贸易有限责任公司库点">光山县同富粮食贸易有限责任公司库点</option></select>
                                    <!-- <select name="ddl_Granary_AutoComplete_DC" id="ddl_Granary_AutoComplete_DC" class="Granary_AutoComplete_DC" mark="GranaryDC" style="display: none">
<option value="">Select one...</option><option value="DC0000000356957" title="guangshanxiantongfuliangshimaoyiyouxianzerengongsikudian">光山县同富粮食贸易有限责任公司库点</option></select><input class="GranaryDC ui-autocomplete-input ui-widget ui-widget-content ui-corner-left" autocomplete="off" role="textbox" aria-autocomplete="list" aria-haspopup="true"><button type="button" style="font-size: 12px; height: 24px;" tabindex="-1" title="显示全部信息！" class="ui-button ui-widget ui-state-default ui-button-icon-only ui-corner-right .ui-button-icon-only" role="button" aria-disabled="false"><span class="ui-button-icon-primary ui-icon ui-icon-triangle-1-s"></span><span class="ui-button-text">&nbsp;</span></button> -->
                                </td>
                                <td class="tbtitle">
                                    时间：
                                </td>
                                <td class="tbright">
                                    &nbsp;<input name="txtTime" type="text" id="txtTime" class="Wdate" onfocus="WdatePicker({skin:'whyGreen',dateFmt:'yyyy-MM-dd',maxDate:'%y-%M-%d'})" readonly="readonly" value="2017-05-23">
                                    &nbsp;&nbsp;<span id="lbWeatherInfo"></span>
                                </td>
                            </tr>
                            <tr class="noboder">
                                <td class="tbtitle">
                                    排序：
                                </td>
                                <td class="tbright" colspan="3">
                                    <select name="selectSortMethod" id="selectSortMethod" class="sortmethod" style="width: 100px;">
	<option selected="selected" value="0">默认</option>
	<option value="1">储备类型</option>
</select>
                                </td>
                            </tr>
                        </tbody></table>
                    </td>
                </tr>
                <tr>
                    <td colspan="4" class="tdbtnNew">
                        &nbsp;
                        <input type="submit" name="btn_Query" value="查 询" id="btn_Query" class="anni1 Query">
                        
                       <!--  <input name="btn_temp" type="button" id="btn_temp" class="RedirectOtherPage anni1" lang="TempOrHumWaringSubNav.aspx" validationgroup="003027" value="温湿度预警">
                        <input name="btn_TestTemp" type="button" id="btn_TestTemp" class="RedirectOtherPage anni1" lang="AutoCheckTempAjaxSub.aspx" validationgroup="003025" value="远程测温" data-canall="0"> -->
                        <input name="storeSort" type="button" id="storeSort" class="anni1" value="汇总↓" title="查看汇总">
                        <input name="btnreturn" type="button" id="btnreturn" class="anni1" value="导航视图" title="导航视图" data-nowgid="DC0000000356957">
                        
                        
                        
                        
                    </td>
                </tr>
            </tbody>
            </table>
           

    <div id="divMask" style="display: none;">
        <div id="loading">
            <div style="text-align: center; color: red; font-size: large; font-weight: bold;
                background-color: White;">
                <img src="imgs/extanim32.gif" alt="" style="width: 32px; height: 32px;" align="absmiddle">
                数据加载中...
            </div>
            <div id="loading-mask">
            </div>
        </div>
        <div style="" id="divB" class="mask">
        </div>
    </div>
    </div>

    <script language="javascript" type="text/javascript">
    function getViewportHeight() {
        if (window.innerHeight != window.undefined) return window.innerHeight;
        if (document.compatMode == 'CSS1Compat') return document.documentElement.clientHeight;
        if (document.body) return document.body.clientHeight;

        return window.undefined;
    }
    function getViewportWidth() {
        if (window.innerWidth != window.undefined) return window.innerWidth;
        if (document.compatMode == 'CSS1Compat') return document.documentElement.clientWidth;
        if (document.body) return document.body.clientWidth;

        return window.undefined;
    }
    function getScrollTop() {
        if (self.pageYOffset) {
            return self.pageYOffset;
        }
        else if (document.documentElement && document.documentElement.scrollTop) {
            return document.documentElement.scrollTop;
        }
        else if (document.body) {
            return document.body.scrollTop;
        }
    }
    function getScrollLeft() {
        if (self.pageXOffset) {
            return self.pageXOffset;
        }
        else if (document.documentElement && document.documentElement.scrollLeft) {
            return document.documentElement.scrollLeft;
        }
        else if (document.body) {
            return document.body.scrollLeft;
        }
    }

    var rT = true; //允许图像过渡
    var bT = true; //允许图像淡入淡出
    var tw = 150; //提示框宽度
    var endaction = false; //结束动画
    var ns4 = document.layers;
    var ns6 = document.getElementById && !document.all;
    var ie4 = document.all;
    offsetX = 10;
    offsetY = 20;
    var toolTipSTYLE = "";
    function initToolTips() {
        tempDiv = document.createElement("div");
        tempDiv.id = "toolTipLayer";
        tempDiv.style.position = "absolute";
        tempDiv.style.display = "none";
        document.body.appendChild(tempDiv);
        if (ns4 || ns6 || ie4) {
            if (ns4) toolTipSTYLE = document.toolTipLayer;
            else if (ns6) toolTipSTYLE = document.getElementById("toolTipLayer").style;
            else if (ie4) toolTipSTYLE = document.all.toolTipLayer.style;
            if (ns4) document.captureEvents(Event.MOUSEMOVE);
            else {
                toolTipSTYLE.visibility = "visible";
                toolTipSTYLE.display = "none";
            }
            document.onmousemove = moveToMouseLoc;
        }
    }
    function toolTip(msg, fg, bg) {
        try {
            if (toolTip.arguments.length < 1) // hide
            {
                if (ns4) {
                    toolTipSTYLE.visibility = "hidden";
                }
                else {
                    if (!endaction) { toolTipSTYLE.display = "none"; }
                    if (rT) document.all("msg1").filters[1].Apply();
                    if (bT) document.all("msg1").filters[2].Apply();
                    document.all("msg1").filters[0].opacity = 0;
                    if (rT) document.all("msg1").filters[1].Play();
                    if (bT) document.all("msg1").filters[2].Play();
                    if (rT) {
                        if (document.all("msg1").filters[1].status == 1 || document.all("msg1").filters[1].status == 0) {
                            toolTipSTYLE.display = "none";
                        }
                    }
                    if (bT) {
                        if (document.all("msg1").filters[2].status == 1 || document.all("msg1").filters[2].status == 0) {
                            toolTipSTYLE.display = "none";
                        }
                    }
                    if (!rT && !bT) toolTipSTYLE.display = "none";
                }
            }
            else {
                if (!fg) fg = "#777777";
                if (!bg) bg = "#eeeeee";
                var htmlstrt = "";
                var list = new Array();
                list = msg.split(',');
                for (var i = list.length - 1; i >= 1; i--) {
                    if (list[i] == "1")//空层
                    { htmlstrt += "<div style='height:15px;width:auto;background-image:url(imgs/ceng.gif); text-align:center;color:Red;'>空</div>"; }
                    else if (list[i] == "2")//数据异常
                    { htmlstrt += "<div style='height:15px;width:auto;background-image:url(imgs/ceng.gif); text-align:center;color:Red;'>测温信息点异常</div>"; }
                    else
                    { htmlstrt += "<div style='background-image:url(imgs/ceng.gif);height:15px;width:auto;text-align:center;'>满</div>"; }
                }
                var content = "<div style='width:95px;text-align:center;'><div style='width:auto;'><img src='imgs/toppp.gif' border='0' /></div>" + htmlstrt + "</div>";
                if (htmlstrt == "")
                { content = msg; }

                if (ns4) {
                    toolTipSTYLE.document.write(content);
                    toolTipSTYLE.document.close();
                    toolTipSTYLE.visibility = "visible";
                }
                if (ns6) {
                    document.getElementById("toolTipLayer").innerHTML = content;
                    toolTipSTYLE.display = 'block'
                }
                if (ie4) {
                    document.all("toolTipLayer").innerHTML = content;
                    toolTipSTYLE.display = 'block'
                    //--图象过渡，淡入处理--
                    var cssopaction = document.all("msg1").filters[0].opacity
                    document.all("msg1").filters[0].opacity = 0;
                    if (rT) document.all("msg1").filters[1].Apply();
                    if (bT) document.all("msg1").filters[2].Apply();
                    document.all("msg1").filters[0].opacity = cssopaction;
                    if (rT) document.all("msg1").filters[1].Play();
                    if (bT) document.all("msg1").filters[2].Play();
                }
            }
        } catch (e) { }
    }
    function moveToMouseLoc(e) {
        var scrollTop = getScrollTop();
        var scrollLeft = getScrollLeft();
        if (ns4 || ns6) {
            x = e.pageX + scrollLeft;
            y = e.pageY - scrollTop;
        }
        else {
            x = event.clientX + scrollLeft;
            y = event.clientY;
        }

        if (x - scrollLeft > getViewportWidth() / 2) {
            x = x - document.getElementById("toolTipLayer").offsetWidth - 2 * offsetX;
        }

        if ((y + document.getElementById("toolTipLayer").offsetHeight + offsetY) > getViewportHeight()) {
            y = getViewportHeight() - document.getElementById("toolTipLayer").offsetHeight - offsetY;
        }
        toolTipSTYLE.left = (x + offsetX) + 'px';
        toolTipSTYLE.top = (y + offsetY + scrollTop) + 'px';
        return true;
    }
    initToolTips();
   
</script>
</body>
</html>